#-------------------------------------------------------------------------------
# extlibs/raknet
#-------------------------------------------------------------------------------
#INCLUDE_DIRECTORIES(
#    ${Nebula3_SOURCE_DIR}/
#    ${Nebula3_SOURCE_DIR}/foundation/
#    ${Nebula3_SOURCE_DIR}/extlibs/
#)
SET(extlibs_raknet_SRCS
    source/_FindFirst.cpp
    source/_FindFirst.h
    source/AsynchronousFileIO.cpp
    source/AsynchronousFileIO.h
    source/AutopatcherPatchContext.h
    source/AutopatcherRepositoryInterface.h
    source/AutoRPC.cpp
    source/AutoRPC.h
    source/BigTypes.h
    source/BitStream.cpp
    source/BitStream.h
    source/BitStream_NoTemplate.cpp
    source/BitStream_NoTemplate.h
    source/CheckSum.cpp
    source/CheckSum.h
    source/ClientContextStruct.h
    source/CommandParserInterface.cpp
    source/CommandParserInterface.h
    source/ConnectionGraph.cpp
    source/ConnectionGraph.h
    source/ConsoleServer.cpp
    source/ConsoleServer.h
    source/DataBlockEncryptor.cpp
    source/DataBlockEncryptor.h
    source/DataCompressor.cpp
    source/DataCompressor.h
    source/DirectoryDeltaTransfer.cpp
    source/DirectoryDeltaTransfer.h
    source/DS_BinarySearchTree.h
    source/DS_BPlusTree.h
    source/DS_BytePool.cpp
    source/DS_BytePool.h
    source/DS_ByteQueue.cpp
    source/DS_ByteQueue.h
    source/DS_Heap.h
    source/DS_HuffmanEncodingTree.cpp
    source/DS_HuffmanEncodingTree.h
    source/DS_HuffmanEncodingTreeFactory.h
    source/DS_HuffmanEncodingTreeNode.h
    source/DS_LinkedList.h
    source/DS_List.h
    source/DS_Map.h
    source/DS_MemoryPool.h
    source/DS_OrderedChannelHeap.h
    source/DS_OrderedList.h
    source/DS_Queue.h
    source/DS_QueueLinkedList.h
    source/DS_RangeList.h
    source/DS_Table.cpp
    source/DS_Table.h
    source/DS_Tree.h
    source/DS_WeightedGraph.h
    source/EmailSender.cpp
    source/EmailSender.h
    source/EncodeClassName.cpp
    source/EpochTimeToString.cpp
    source/EpochTimeToString.h
    source/Export.h
    source/ExtendedOverlappedPool.cpp
    source/ExtendedOverlappedPool.h
    source/FileList.cpp
    source/FileList.h
    source/FileListNodeContext.h
    source/FileListTransfer.cpp
    source/FileListTransfer.h
    source/FileListTransferCBInterface.h
    source/FileOperations.cpp
    source/FileOperations.h
    source/FormatString.cpp
    source/FormatString.h
    source/FullyConnectedMesh.cpp
    source/FullyConnectedMesh.h
    source/FunctionThread.cpp
    source/FunctionThread.h
    source/Gen_RPC8.cpp
    source/Gen_RPC8.h
    source/GetTime.cpp
    source/GetTime.h
    source/GridSectorizer.cpp
    source/GridSectorizer.h
    source/HTTPConnection.cpp
    source/HTTPConnection.h
    source/IncrementalReadInterface.cpp
    source/IncrementalReadInterface.h
    source/InlineFunctor.cpp
    source/InlineFunctor.h
    source/InternalPacket.h
    source/Itoa.cpp
    source/Itoa.h
    source/Kbhit.h
    source/LightweightDatabaseClient.cpp
    source/LightweightDatabaseClient.h
    source/LightweightDatabaseCommon.cpp
    source/LightweightDatabaseCommon.h
    source/LightweightDatabaseServer.cpp
    source/LightweightDatabaseServer.h
    source/LinuxStrings.cpp
    source/LinuxStrings.h
    source/LogCommandParser.cpp
    source/LogCommandParser.h
    source/MessageFilter.cpp
    source/MessageFilter.h
    source/MessageIdentifiers.h
    source/MTUSize.h
    source/NatPunchthrough.cpp
    source/NatPunchthrough.h
    source/NetworkIDManager.cpp
    source/NetworkIDManager.h
    source/NetworkIDObject.cpp
    source/NetworkIDObject.h
    source/PacketConsoleLogger.cpp
    source/PacketConsoleLogger.h
    source/PacketFileLogger.cpp
    source/PacketFileLogger.h
    source/PacketLogger.cpp
    source/PacketLogger.h
    source/PacketPool.h
    source/PacketPriority.h
    source/PluginInterface.cpp
    source/PluginInterface.h
    source/RakAssert.h
    source/RakMemoryOverride.cpp
    source/RakMemoryOverride.h
    source/RakNetCommandParser.cpp
    source/RakNetCommandParser.h
    source/RakNetDefines.h
    source/RakNetStatistics.cpp
    source/RakNetStatistics.h
    source/RakNetTransport.cpp
    source/RakNetTransport.h
    source/RakNetTypes.cpp
    source/RakNetTypes.h
    source/RakNetVersion.h
    source/RakNetworkFactory.cpp
    source/RakNetworkFactory.h
    source/RakPeer.cpp
    source/RakPeer.h
    source/RakPeerInterface.h
    source/RakSleep.cpp
    source/RakSleep.h
    source/RakString.cpp
    source/RakString.h
    source/RakThread.cpp
    source/RakThread.h
    source/Rand.cpp
    source/Rand.h
    source/ReadyEvent.cpp
    source/ReadyEvent.h
    source/RefCountedObj.h
    source/ReliabilityLayer.cpp
    source/ReliabilityLayer.h
    source/Replica.h
    source/ReplicaEnums.h
    source/ReplicaManager2.cpp
    source/ReplicaManager2.h
    source/ReplicaManager.cpp
    source/ReplicaManager.h
    source/rijndael.cpp
    source/Rijndael.h
    source/Rijndael-Boxes.h
    source/Router.cpp
    source/Router.h
    source/RouterInterface.h
    source/RPCMap.cpp
    source/RPCMap.h
    source/RPCNode.h
    source/RSACrypt.h
    source/SHA1.cpp
    source/SHA1.h
    source/SimpleMutex.cpp
    source/SimpleMutex.h
    source/SimpleTCPServer.h
    source/SingleProducerConsumer.h
    source/SocketLayer.cpp
    source/SocketLayer.h
    source/StringCompressor.cpp
    source/StringCompressor.h
    source/StringTable.cpp
    source/StringTable.h
    source/SuperFastHash.cpp
    source/SuperFastHash.h
    source/SystemAddressList.cpp
    source/SystemAddressList.h
    source/TableSerializer.cpp
    source/TableSerializer.h
    source/TCPInterface.cpp
    source/TCPInterface.h
    source/TelnetTransport.cpp
    source/TelnetTransport.h
    source/ThreadPool.h
    source/ThreadsafePacketLogger.cpp
    source/ThreadsafePacketLogger.h
    source/TransportInterface.h
    source/Types.h
    source/WSAStartupSingleton.cpp
    source/WSAStartupSingleton.h
)

ADD_LIBRARY(RakNet STATIC ${extlibs_raknet_SRCS})
N_SET_COMPILER_DEFAULTS()
IF(MSVC)
    ADD_DEFINITIONS(/D_CRT_SECURE_NO_WARNINGS)
ENDIF()
